@switch($data['upload_type'])
    @case(11)
        <div class="layui-form-item">
            <label class="layui-form-label">{{$data['info']}}</label>
            <div class="layui-input-inline">
                <input type="text" name="file_path" id="file_path" placeholder="请上传图片" autocomplete="off" class="layui-input">
                <input type="hidden" name="file_id" id="file_id" placeholder="请上传图片" autocomplete="off" class="layui-input">
                <input type="hidden" name="file_name" id="file_name" placeholder="请上传图片" autocomplete="off" class="layui-input">
            </div>
            <button type="button" class="layui-btn" id="test-upload-normal" style="float: left">上传图片</button>
            <div class="layui-upload-list  " style="width: 100px;float: left;margin-left: 20px">
                <img class="layui-upload-img"  style="width: 40px;height: 40px" id="test-upload-normal-img">
                <p id="upload-Text"></p>
            </div>
        </div>
        @break

    @case(3)
        <div class="layui-form-item">
            <label class="layui-form-label">{{$data['info']}}</label>
            <div class="layui-input-inline">
                <input type="text" name="file_path" id="file_path" placeholder="请上传图片" autocomplete="off" class="layui-input" value="{{@get_file_info($data['value']??'')->file_name}}">
                <input type="hidden" name="{{$data['menu_name']}}" id="{{$data['menu_name']}}" value="{{$data['value']??''}}" class="layui-input input-menu-name">
                <input type="hidden" name="file_id" id="file_id" placeholder="请上传图片" value="{{$data['value']??''}}"  autocomplete="off" class="layui-input">
                <input type="hidden" name="file_name" id="file_name" placeholder="请上传图片" autocomplete="off" class="layui-input">
            </div>
            <button type="button" class="layui-btn" id="test-upload-norma{{$id}}" style="float: left">上传图片</button>
            <div class="layui-upload-list  " style="width: 100px;float: left;margin-left: 20px">
                <p id="upload-Text"></p>
            </div>

        </div>
    <script>
        layui.config({
            base: '../' //静态资源所在路径
        }).use([ 'table', 'form','upload'], function(){
            var $ = layui.$
                ,form = layui.form
                ,upload = layui.upload ;


            //普通图片上传
            var eleId = "#test-upload-norma{{$id}}";
            var postUrl = "/admin/file/upload";
            var layUpload = upload;
            var exts = '';
            Common.uploadFile(eleId, postUrl, layUpload, "#test-upload-normal-img{{$id}}", exts)


        });//use

    </script>
        @break


    @default
        <div class="layui-form-item">
            <label class="layui-form-label">{{$data['info']}}</label>
            <div class="layui-input-inline">
                <input type="text" name="file_path" id="file_path" placeholder="请上传图片" autocomplete="off" class="layui-input" value="{{@get_file_info($data['value']??'')->file_name}}">
                <input type="hidden" name="{{$data['menu_name']}}" id="{{$data['menu_name']}}" value="{{$data['value']??''}}" class="layui-input input-menu-name">
                <input type="hidden" name="file_id" id="file_id" placeholder="请上传图片" value="{{$data['value']??''}}"  autocomplete="off" class="layui-input">
                <input type="hidden" name="file_name" id="file_name" placeholder="请上传图片" autocomplete="off" class="layui-input">
            </div>
            <button type="button" class="layui-btn" id="test-upload-norma{{$id}}" style="float: left">上传图片</button>
            <div class="layui-upload-list  " style="width: 100px;float: left;margin: 0px 5px">
                <img class="layui-upload-img" src="{{@get_file_info($data['value']??'')->file_url}}"  style="width: 40px;height: 40px;" id="test-upload-normal-img{{$id}}">
                <p id="upload-Text"></p>
            </div>

        </div>

    <script>
        layui.config({
            base: '../' //静态资源所在路径
        }).use([ 'table', 'form','upload'], function(){
            var $ = layui.$
                ,form = layui.form
                ,upload = layui.upload ;


            //普通图片上传
            var eleId = "#test-upload-norma{{$id}}";
            var postUrl = "/admin/file/upload";
            var layUpload = upload;
            var exts = 'jpg|png|gif|bmp|jpeg';
            Common.uploadFile(eleId, postUrl, layUpload, "#test-upload-normal-img{{$id}}", exts)

            $("#file_id").change(function () {
                var file_id = $(this).val();
                $(this).siblings('.input-menu-name').val(file_id);
            })


        });//use

    </script>
        @break

@endswitch
